package com.api.weavernorth.salaryXJ;

import com.alibaba.fastjson.JSONArray;
import com.alibaba.fastjson.JSONObject;
import com.weavernorth.util.Logger4jUtil;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.log4j.Logger;
import weaver.conn.RecordSet;
import weaver.general.BaseBean;
import weaver.general.Util;

import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.ws.rs.GET;
import javax.ws.rs.Path;
import javax.ws.rs.Produces;
import javax.ws.rs.core.Context;
import javax.ws.rs.core.MediaType;
import java.math.BigDecimal;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Calendar;
import java.util.Date;

/**
 * @Author: bruseewang
 * @Package: com.api.weavernorth.salary
 * @date: 2020/5/19 13:15
 * @description: 查询建模表中店铺人员销售信息
 */
@Path("/weavernorth/salaryXJ")
public class V8InfoInXj extends HttpServlet {
//    private static Log log = LogFactory.getLog(V8InfoInXj.class);
private Logger log = Logger4jUtil.getLoggerByName("/action/api/V8InfoInXj/");
    /**
     * 终端店铺销售提成申请表流程获取主表与明细表信息
     *
     * @param request
     * @param response
     * @return
     */
    @GET
    @Path("/getV8messForXJ")
    @Produces(MediaType.TEXT_PLAIN)
    public String getV8mess(@Context HttpServletRequest request, @Context HttpServletResponse response) {
        BaseBean bb=new BaseBean();
        //数据库操作
        RecordSet rs = new RecordSet();
        //数据操作
        //返回信息
        JSONArray jsonArray = new JSONArray();
        //返回所有数据
        JSONObject json = new JSONObject();
        //销售总流水
        JSONObject jsonMain = new JSONObject();

        //部门id
        String strDpbh = Util.null2String(request.getParameter("dpbh"));
        //操作日期
        String strCzrq = Util.null2String(request.getParameter("sqsj"));
        // String preMonthDay = getPreMonth(strCzrq);
        String preMonthDay = strCzrq;
        //操作日期年月
        String strCzrqYearMonth = "";
        //得到操作日期的年份和月
        if (!"".equals(preMonthDay)) {
            strCzrqYearMonth = preMonthDay.split("-")[0] + preMonthDay.split("-")[1];

        }
        //店铺小程序正价总流水
        BigDecimal xcxzjlsMain=new BigDecimal("0.0");
        //店铺小程序折价总流水
        BigDecimal xcxzhejlsMain=new BigDecimal("0.0");
        //查询建模表信息

        //销售业绩汇总表：uf_xsyjhzb
        //终端小程序销售业绩：uf_zdxcxxsyj
        // String sql = "select * from uf_xsyjhzb where dpbm=? and xzrq=?  and  ((gwdm='01' and sfzls=0) or gwdm='02')";
        String sql = "select a.*,b.xcxzjxs,b.xcxzjxss from uf_xsyjhzb a LEFT JOIN uf_zdxcxxsyj b ON a.DPBM=b.sapdpbm AND a.XZRQ=b.xsqj " +
                "AND a.ygh=b.ygbh where a.dpbm=? and a.xzrq=?  ORDER BY a.GWDM ASC";
        log.info("查询建模表中店铺信息:" + sql + ",strDpbh:" + strDpbh + ",strCzrqYearMonth:" + strCzrqYearMonth);
        rs.executeQuery(sql, strDpbh, strCzrqYearMonth);
        while (rs.next()) {
            JSONObject jsonObject = new JSONObject();
            //员工id
            String strUserid = Util.null2String(rs.getString("ygxm"));
            jsonObject.put("userid", strUserid);
            //员工名称
            String strUserName = Util.null2String(rs.getString("ygmc"));
            jsonObject.put("username", strUserName);
            //员工编码
            String strWorkcode = Util.null2String(rs.getString("ygh"));
            jsonObject.put("workcode", strWorkcode);
            //月任务
            String strMonthTask = Util.null2String(rs.getString("yrw"));
            jsonObject.put("monthtask", strMonthTask);

            //正价销售
//            String strValSales = Util.null2String(rs.getString("zjxs"));
//            jsonObject.put("valsales", strValSales);
//            //折价销售
//            String strDisSales = Util.null2String(rs.getString("zhejxs"));
//            jsonObject.put("dissales", strDisSales);
            //岗位id
            String strGwmc = Util.null2String(rs.getString("gwmc"));
            jsonObject.put("jobid", strGwmc);
            //岗位名称
            String strJobName = Util.null2String(rs.getString("zwmc"));
            jsonObject.put("jobname", strJobName);
            //岗位代码
            String strGwdm = Util.null2String(rs.getString("gwdm"));
            jsonObject.put("gwdm", strGwdm);

            //微销正价销售额
            String strwxzjls_detail = Util.null2String(rs.getString("wxzjls"));
            jsonObject.put("wxzjls", strwxzjls_detail);
            //微销折价销售额
            String strwxzjlss_detail = Util.null2String(rs.getString("wxzjlss"));
            jsonObject.put("wxzjlss", strwxzjlss_detail);
            //团购正价销售额
            String strtgzjls_detail = Util.null2String(rs.getString("tgzjls"));
            jsonObject.put("tgzjls", strtgzjls_detail);
            //团购折价销售额
            String strtgzjlss_detail = Util.null2String(rs.getString("tgzjlss"));
            jsonObject.put("tgzjlss", strtgzjlss_detail);

            //微信小程序正价销售额
            String strxcxzjxs=Util.null2String(rs.getString("xcxzjxs"));
            jsonObject.put("xcxzjxse", strxcxzjxs);
            //微信小程序折价销售额
            String strxcxzjxss=Util.null2String(rs.getString("xcxzjxss"));
            jsonObject.put("xcxzhejxse", strxcxzjxss);

            //小程序正价流水汇总strxcxzjxs
            String strls1="0.0";
            if(!"".equals(strxcxzjxs)&&strxcxzjxs!=null)
            {
                strls1=strxcxzjxs;
            }
            BigDecimal x1=new BigDecimal(strls1);
            xcxzjlsMain=xcxzjlsMain.add(x1);
            //小程序折价流水汇总
            String strls2="0.0";
            if(!"".equals(strxcxzjxss)&&strxcxzjxss!=null)
            {
                strls2=strxcxzjxss;
            }
            BigDecimal x2=new BigDecimal(strls2);
            xcxzhejlsMain=xcxzhejlsMain.add(x2);
            //销售总流水
            String strxsslsDetail = Util.null2String(rs.getString("xszls"));
            jsonObject.put("xszls", strxsslsDetail);
            //是否总流程
            String strSfzls = Util.null2String(rs.getString("sfzls"));
            //如果为总流水,放入单独的json里,表单显示在主表里
            if ("0".equals(strSfzls)) {//Y
                //支援正价总计
                String strZyzj = Util.null2String(rs.getString("zyzj"));
                jsonObject.put("zyzls", strZyzj);
                //支援折价总计
                String strZzyzj = Util.null2String(rs.getString("zyzhej"));
                jsonObject.put("zyzhej", strZzyzj);
                //销售总流水
                String strXszls = Util.null2String(rs.getString("xszls"));
                jsonObject.put("xszls", strXszls);
                //支援总流水
                String strZyzls = Util.null2String(rs.getString("zyzls"));
                jsonObject.put("zyzls", strZyzls);
                //微销正价流水
                String strwxzjls=Util.null2String(rs.getString("wxzjls"));
                jsonObject.put("wxzjls", strwxzjls);
                //微销折价流水
                String strwxzjlss=Util.null2String(rs.getString("wxzjlss"));
                jsonObject.put("wxzjlss", strwxzjlss);
                //团购正价流水
                String strtgzjls=Util.null2String(rs.getString("tgzjls"));
                jsonObject.put("tgzjls", strtgzjls);
                //团购折价流水
                String strtgzjlss=Util.null2String(rs.getString("tgzjlss"));
                jsonObject.put("tgzjlss", strtgzjlss);
                jsonMain = jsonObject;
            }

            //员工编号不为空时,添加到明细
            if (!"".equals(strWorkcode)) {
                //查找小程序信息
                jsonArray.add(jsonObject);
            }
            //返回数据
        }
        bb.writeLog("小程序正价总流水汇总："+xcxzjlsMain+";小程序折价总流水汇总："+xcxzhejlsMain);
        jsonMain.put("xcxzjls",xcxzjlsMain.toString());//小程序正价总流水xcxzjlsMain.toString()
        jsonMain.put("xcxzhejls",xcxzhejlsMain.toString());//小程序折价总流水xcxzhejlsMain.toString()
        json.put("maindata", jsonMain);
        json.put("detaildata", jsonArray);

        return json.toString();
    }

    /**
     * 当完成比改变时,获取正价提率等信息
     *
     * @param request
     * @param response
     * @return
     */
    @GET
    @Path("/percenCompleteFoXJ")
    @Produces(MediaType.TEXT_PLAIN)
    public String percenComplete(@Context HttpServletRequest request, @Context HttpServletResponse response) {
        //数据库操作
        RecordSet rs = new RecordSet();
        RecordSet rsWcl = new RecordSet();
        //返回值
        JSONArray jsonArray = new JSONArray();
        //店铺编码
        String strDpbh = Util.null2String(request.getParameter("dpbh"));
        //完成比
        Double souWcb = Util.getDoubleValue(request.getParameter("wcbVal"), 0.0);
        //岗位编码
        String strJobCode = Util.null2String(request.getParameter("jobcode"));
        //申请时间,提率需要用前一个月去对比
        String sqsjVal = Util.null2String(request.getParameter("sqsjVal"));
        //店铺完成率
        Double douDpwcl = Util.getDoubleValue(request.getParameter("dpwcl"), 0.0);
        //得到申请时间的前一个月
        // String preMonthDay = getPreMonth(sqsjVal);

        String preMonthDay = sqsjVal;
        //店经理个人完成率
        Double douMangeRate = 0.0;
        //首先得到店经理的个人完成率
        String sqlWcl = "select djlgrwcl from uf_xstcgzxx_xj ux,uf_xstcgzxx_xj_dt1 uxd,uf_dpsygzgxb_xj1 ud where ud.gzbh = ux.id and ux.id=uxd.mainid" +
                " and ud.dpbh=? and uxd.gwdm='01' and ud.yxksrq<=? and ud.yxjsrq>=?";
        log.info("得到店经理的个人完成率:" + sqlWcl + ",strDpbh:" + strDpbh + ",preMonthDay:" + preMonthDay);
        rsWcl.executeQuery(sqlWcl, strDpbh, preMonthDay, preMonthDay);
        if (rsWcl.next()) {
            douMangeRate = Util.getDoubleValue(rsWcl.getString("djlgrwcl"), 0.0);
        }
        log.info("店经理的个人完成率:" + douMangeRate);
        //如果店经理的销售完成率大于规则表维护的完成率,则取店铺的销售完成率
//        if (souWcb >= douMangeRate && "01".equals(strJobCode)) {
//            souWcb = douDpwcl;
//        } else if (souWcb < douMangeRate && "01".equals(strJobCode)) {
//            souWcb = 0.0;
//        }
        log.info("当前销售完成比:" + souWcb);

        //查询提率和保底金额,规则表和规则关系表联查,在有效期内且完成比在销售完成率上下线之间
        //xswclsx:销售完成率上限；xswclsx：销售完成率下限；xswclxx：有效开始日期，yxjsrq：有效结束日期
        //根据店铺编号，岗位编号，前一个月日期，店铺完成率查询
        String sql = "select * from uf_xstcgzxx_xj ux,uf_xstcgzxx_xj_dt1 uxd,uf_dpsygzgxb_xj1 ud where ud.gzbh = ux.id and ux.id=uxd.mainid" +
                " and ud.dpbh=? and uxd.gwdm=? and ud.yxksrq<=? and ud.yxjsrq>=? and uxd.xswclxx<=? and uxd.xswclsx>?";
        log.info("得到提率和保底金额:" + sql + ",strDpbh:" + strDpbh + ",strJobCode:" + strJobCode + ",preMonthDay:" + preMonthDay + ",souWcb:" + souWcb);
        rs.executeQuery(sql, strDpbh, strJobCode, preMonthDay, preMonthDay, souWcb, souWcb);
        while (rs.next()) {
            JSONObject jsonObject = new JSONObject();
            //提率
            String strTl = Util.null2String(rs.getString("tl"));
            jsonObject.put("tl", strTl);
            log.info("得到提率:" + strTl);
            //超额提率
            String strChaoEtl = Util.null2String(rs.getString("cetl"));
            jsonObject.put("cetl", strChaoEtl);
            log.info("得到超额提率:" + strChaoEtl);

            String strSfzj = Util.null2String(rs.getString("sfzj"));
            jsonObject.put("sfzj", strSfzj);
            log.info("是否正价:" + strSfzj);
            //保底金
            String strBdje = Util.null2String(rs.getString("bdje"));
            jsonObject.put("bdje", strBdje);
            //淡旺季编号
            String strDwj = Util.null2String(rs.getString("dwj"));
            //得到不需要的数据的id
            String strDw = getDwSeson(strDwj, preMonthDay);
            log.info("淡旺季返回的值:" + strDw);
            //根据前一个月判断淡旺季,然后得到返回的当前季节和全年的数据
            if (("".equals(strDw))) {
                jsonArray.add(jsonObject);
            }
        }
        //判断数组是否为空,否则返回""
        if (jsonArray != null) {
            return jsonArray.toString();
        } else {
            return "";
        }

    }


    /**
     * 得到淡旺季标识
     *
     * @param strDate 申请时间的前一个月
     */
    public String getDwSeson(String strDwId, String strDate) {
        RecordSet rs = new RecordSet();
        //得到年份
        int intYear = Integer.parseInt(strDate.split("-")[0]);
        //当前日期
        Date date = new Date();
        SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd");
        String strCurr = format.format(date);
        //当前月份
        String strCurrMonth = strCurr.split("-")[1];

        //返回信息
        String strBs = "";
        //在有效期内的
        String sql = "select * from uf_dwjczb where id=? and  yxksrq<=? and yxjsrq>=?";
        //判断是否需要全年的编码
        log.info("查询淡旺季:" + sql + ",id:" + strDwId + ",strDate:" + strDate);
        rs.executeQuery(sql, strDwId, strDate, strDate);
        while (rs.next()) {
            //开始月份
            int intKsyf = Util.getIntValue(rs.getString("ksyf"));
            //开始年月日
            String strBeginDate = String.valueOf(intYear) + "-" + String.format("%02d", Integer.valueOf(intKsyf)) + "-01";
            //结束月份
            int intJsyf = Util.getIntValue(rs.getString("jsyf"));
            //结束日期
            String strEndDate = String.valueOf(intYear) + "-" + String.format("%02d", Integer.valueOf(intJsyf)) + "-01";
            //淡旺季标识
            String strDwj = Util.null2String(rs.getString("dwj"));
            //是否跨年
            String strSfkn = Util.null2String(rs.getString("sfkn"));
            log.info("是否跨年:" + strSfkn);
            //如果跨年,则结束月份年份加1
            if ("1".equals(strSfkn)) {
                log.info("开始月份:" + intKsyf);
                log.info("当前月份:" + strCurrMonth);
                log.info("年份:" + intYear);
                //跨年的话,再比较当前月份是否小于开始月份
                if (intKsyf > Integer.parseInt(strCurrMonth)) {
                    strBeginDate = String.valueOf(intYear - 1) + "-" + String.format("%02d", Integer.valueOf(intKsyf)) + "-01";
                } else {
                    strEndDate = String.valueOf(intYear + 1) + "-" + String.format("%02d", Integer.valueOf(intJsyf)) + "-01";
                }
            }
            log.info("开始日期:" + strBeginDate + ",结束日期:" + strEndDate + ",传入标识:" + strDate);
            //返回不在当前月份的编号
            if (!(strBeginDate.compareTo(strDate) <= 0 && strEndDate.compareTo(strDate) >= 0)) {
                log.info("返回淡旺季标识:" + strDwId);
                return strDwId;
            }

        }

        return strBs;
    }

    /**
     * 得到零售经理和区域经理的任务总和,销售总流水
     *
     * @return
     */

    @GET
    @Path("/retailmessForXJ")
    @Produces(MediaType.TEXT_PLAIN)
    public String getRetailMess(@Context HttpServletRequest request, @Context HttpServletResponse response) {
        //用户id
        String strUserid = Util.null2String(request.getParameter("userid"));
        //查询的字段名称
        String strZdmc = Util.null2String(request.getParameter("zdmc"));
        //操作日期
        String strCzrq = Util.null2String(request.getParameter("czrq"));
        //获取当前年月
        //  SimpleDateFormat format = new SimpleDateFormat("yyyy-MM");
        //分公司
        String strFgsVal = Util.null2String(request.getParameter("fgsVal"));

        String strYearMonth = strCzrq.split("-")[0] + strCzrq.split("-")[1];
        //是否按全地区销售业绩计算
        String strSfqdq = Util.null2String(request.getParameter("sfaqdqxsyjjs"));

        //数据库操作
        RecordSet rs = new RecordSet();
        JSONObject json = new JSONObject();
        //根据人员得到所管辖的店铺,所有店铺的汇总信息
        StringBuffer strDpsql = new StringBuffer("select  sum(yrw) yrwhz,sum(xszls) xlzls  from uf_dpxx ud,uf_xsyjhzb ux where ud.dpsapid=ux.dpbm and  ','||ud." + strZdmc + "||','  like   '%," + strUserid + ",%' and ux.sfzls='0' and ux.xzrq=? and ud.fgs=?");
        rs.executeQuery(strDpsql.toString(), strYearMonth, strFgsVal);
        if ("1".equals(strSfqdq)) {
            //销售业绩归属人
            String strXsyjgsr = Util.null2String(request.getParameter("xsyjgsr"));
            if (!"".equals(strXsyjgsr)) {
                strDpsql.append(" and ");
                String[] arrGsr = strXsyjgsr.split(",");
                for (int i = 0;i < arrGsr.length; i++) {
                    strDpsql.append(" (ud.lsjl ='" + arrGsr + "' ");
                    if (i != arrGsr.length - 1) {
                        strDpsql.append(" or ");
                    } else {
                        strDpsql.append(" )");
                    }

                }
            }
            log.info("销售业绩归属人:" + strXsyjgsr);

            rs.executeQuery(strDpsql.toString(), strYearMonth, strFgsVal, strXsyjgsr);
        }
        log.info("获取销售总任务和总流水:" + strDpsql + ",strUserid:" + strUserid + ",strYearMonth:" + strYearMonth + ",strFgsVal:" + strFgsVal);

        if (rs.next()) {
            json.put("yrw", Util.getDoubleValue(rs.getString("yrwhz"), 0));
            json.put("xlzls", Util.getDoubleValue(rs.getString("xlzls"), 0));
        }
        if (json != null) {
            return json.toString();
        } else {
            return "";
        }
    }

    /**
     * 得到零售经理的销售提成
     *
     * @return 奖金金额
     */

    @GET
    @Path("/getTcjeForXj")
    @Produces(MediaType.TEXT_PLAIN)
    public String getTcje(@Context HttpServletRequest request, @Context HttpServletResponse response) {
        //数据库操作
        RecordSet rs = new RecordSet();
        //奖金金额
        String strJjje = "";
        //分公司id
        String strSubcomId = Util.null2String(request.getParameter("fgsVal"));
        //完成比
        Double douWcl = Util.getDoubleValue(request.getParameter("wclVal"));
        //分公司月任务总和
        Double douFgwrw = Util.getDoubleValue(request.getParameter("fgsrwVal")) / 10000;
        //申请时间
        String strSqsj = Util.null2String(request.getParameter("czrqVal"));
        //获取申请时间的前一个月
//        String preMonthDay = getPreMonth(strSqsj);
        String preMonthDay = strSqsj;
        //查询有效提成
        String sql = "select * from uf_sygzjlblsjl us,uf_jjdfs_lsjl uj,uf_jjdfs_lsjl_dt1 ujd where us.gzbh = uj.id  and uj.id =ujd.mainid " +
                "and us.fgs=? and  us.yxksrq<=? and us.yxjsrq>=?   and ujd.rwdwxx<=? and ujd.rwdwsx>=?" +
                "   and ujd.wcjjdxx<=? and ujd.wcjjdsx>=?";
        log.info("查询零售经理的销售金额:" + sql + ";strSubcomId:" + strSubcomId + ";preMonthDay:" + preMonthDay + ";douFgwrw:" + douFgwrw + ";douWcl:" + douWcl);
        rs.executeQuery(sql, strSubcomId, preMonthDay, preMonthDay, douFgwrw, douFgwrw, douWcl, douWcl);
        if (rs.next()) {
            strJjje = Util.null2String(rs.getString("jjjey"));

        }
        return strJjje;

    }

    /**
     * 得到区域经理的销售提成
     *
     * @return 奖金金额
     */

    @GET
    @Path("/getMangerTcjeForXJ")
    @Produces(MediaType.TEXT_PLAIN)
    public String getMangerTcje(@Context HttpServletRequest request, @Context HttpServletResponse response) {
        //数据库操作
        RecordSet rs = new RecordSet();
        //奖金金额
        String strJjje = "";
        //分公司id
        String strSubcomId = Util.null2String(request.getParameter("fgsVal"));
        //完成比
        Double douWcl = Util.getDoubleValue(request.getParameter("wclVal"));
        //分公司月任务总和
        Double douFgwrw = Util.getDoubleValue(request.getParameter("fgsrwVal")) / 10000;
        //申请时间
        String strSqsj = Util.null2String(request.getParameter("czrqVal"));
        //获取申请时间的前一个月
        //String preMonthDay = getPreMonth(strSqsj);
        String preMonthDay = strSqsj;
        //查询有效提成
        String sql = "select * from uf_sygzjlb_qyjl us,uf_jjdfs_qyjl uj,uf_jjdfs_qyjl_dt1 ujd where us.gzbh = uj.id  and uj.id =ujd.mainid " +
                "and us.fgs=? and  us.yxksrq<=? and us.yxjsrq>=?   and ujd.rwdwxx<=? and ujd.rwdwsx>=?" +
                "   and ujd.wcjjdxx<=? and ujd.wcjjdsx>=?";
        log.info("查询区域经理的销售金额:" + sql + ";strSubcomId:" + strSubcomId + ";preMonthDay:" + preMonthDay + ";douFgwrw:" + douFgwrw + ";douWcl:" + douWcl);
        rs.executeQuery(sql, strSubcomId, preMonthDay, preMonthDay, douFgwrw, douFgwrw, douWcl, douWcl);
        if (rs.next()) {
            strJjje = Util.null2String(rs.getString("jjjey"));

        }
        return strJjje;

    }


    /**
     * 得到办公室人员的销售提成
     *
     * @return 奖金金额
     */

    @GET
    @Path("/getOfficeTcjeForXJ")
    @Produces(MediaType.TEXT_PLAIN)
    public String getOfficeTcje(@Context HttpServletRequest request, @Context HttpServletResponse response) {
        //数据库操作
        RecordSet rs = new RecordSet();
        //奖金金额
        String strJjje = "";
        //完成比
        Double douWcl = Util.getDoubleValue(request.getParameter("wclVal"));
        //规则id
        String strGzid = Util.null2String(request.getParameter("tcge"));
        //查询有效提成
        String sql = "select jjjey  from uf_jjdfs_bgsry uj,uf_jjdfs_bgsry_dt1 ud where uj.id=ud.mainid and uj.id=? and ud.wclxx<=? and ud.wclsx>?";

        log.info("查询办公室人员的销售金额:" + sql + ";douWcl:" + douWcl + ";strGzid:" + strGzid);
        rs.executeQuery(sql, strGzid, douWcl, douWcl);
        if (rs.next()) {
            strJjje = Util.null2String(rs.getString("jjjey"));

        }
        return strJjje;

    }


    /**
     * 返回日期的前一个与的1号
     */

    public String getPreMonth(String sqsjVal) {
        SimpleDateFormat format = new SimpleDateFormat("yyyy-MM");
        Calendar calendar = Calendar.getInstance();
        Date time1 = new Date();
        try {
            // 将字符串转换成日期
            time1 = format.parse(sqsjVal);
        } catch (ParseException e) {
            e.printStackTrace();
        }
        calendar.setTime(time1);
        // 设置为上一个月
        calendar.set(Calendar.MONTH, calendar.get(Calendar.MONTH) - 1);
        //申请时间的上个月
        String preMonth = format.format(calendar.getTime());
        //拼接年月日
        String preMonthDay = preMonth + "-01";
        return preMonthDay;

    }


    /**
     * 检查人员是否存在重复的
     */
    @GET
    @Path("/checkUserForXJ")
    public String checkUser(String strUserid) {
        String strReturn = "";
        return strReturn;


    }


}
